<template>
  <label v-if="props.mode === 'create'" class="py-3 form-item-inline gap-2 justify-end">
    <div>继续添加</div>
    <switch type="checkbox" :check="model" color="#10b981" @change="model = !model" />
  </label>
</template>

<script setup lang='ts'>

interface IProps {
  mode: 'create' | 'update'
}

const props = withDefaults(defineProps<IProps>(), {
  mode: 'create',
})

const model = defineModel<boolean>()

</script>

<style></style>